Contents   Index

Setting up a Code Library

I recently received an email with a query about the Code Library not working correctly.
It turned out thay were using a very old version of geoSurvey, more than 2 years old
and were using an MST file as the code library.

The MST file system was the original code library system designed when GeoSurvey was first written.
Since then the industry standard has been to use XML files for storage of this type of data.
They are easier for a human to understand.

The MST file had a point definition like this:
Point,TR,TR,N,Trees,GREEN,,M,

An equivalent XMl file point definition is like this:
<point code="TR*" symbol="TR" contourable="no" layer="Trees" colour="GREEN" style="4" thickness="1" textSize="3.6" textAngle="51" symbolSize="3.8" />

The second one is easier to read and change.

To change either file, you will need a Text Editor such as Notepad, UltraEdit or crimson Editor.
Notepad is installed in every Windows PC. To start Notepad, click on the Strat menu and type 'Notepad' and open the file.
Do NOT edit these files with Wordpad or Microsoft Word.
You can buy UltraEdit, simply Google 'Ultraedit' and get it.
Crimson Editor is a Freeware text editor that I have used for many years.
It is free and available easily, Google 'Crimson Editor', select the download link and install it.

Auto String Formation

You can define the rules to be used to automatically form strings and place them onto layers
<stringCodes>
   <string code="KB*" type="Discon" discon="yes" layer="field obs" colour="BROWN" style="23" thickness="2" />

This will create a string(say) joining all points coded KB1, set it onto the "field_obs" layer with a Brown colour using line style 23 etc.
You can see a detailed explantion of how to setup the String definitions here.

Code *

If you might observed multiple strings in the field, say KB1, KB2, KB3...
There is a short hand way to define there, simple use 'KB*', this means:
1. Any points iwth a code starting with 'KB' will match.
2. Any extra characters will be used to find points with exactly the same code.

Auto Point Symbolisation

You can define the rules to be used to automatically assign symbols to points and place them onto layers
<stringCodes>
   <point code="TR*" symbol="TR" contourable="no" layer="Trees" colour="GREEN" style="4" thickness="1" textSize="3.6" textAngle="51" symbolSize="3.8" />

This will assign a Tree symbol to each point coded TR, it will place them onto the "Trees" layer with a Green colour using symbol size 3.8mm etc.
You can see a detailed explantion of how to setup the Point definitions here.

Suggested Seup 1

Create a Standard Job.acs which has no pointsor strings but has all the required layers.
Also define each layer with the desired colour, style, symbol etc.
Now create the code library <stringCode> and <pointCode> definitions to referto those layers.
You can leave out most of the other parameters like colour, style etc as they are defined in the layers.
This approach makes your string/point definitions pretty simple.
You can add extra codes/layers for seldom used features, these can have detailed definitions.

Suggested Seup 2

You don't need a standard job. Create the code library <stringCode> and <pointCode> definitions to with full details of how
you want these codes to be treated including the layer, colour, syle, symbols etc.
When you use the Form Strings option, the layers will be created using these rules.
The disadvantage is that no other layers you may need will be created (e.g. design layers).